package com.project.bean;

import com.fasterxml.jackson.annotation.JsonFormat;

import java.time.LocalDate;

/**
 * 员工实体类
 */
public class EmployeeBean {
    /**员工编号*/
    private int id;
    /**姓名*/
    private String name;
    /**生日*/
    @JsonFormat(pattern = "yyyy-MM-dd")
    private LocalDate birthday;
    /**工资*/
    private int money;
    /**部门*/
    private DeptBean dept;

    public EmployeeBean() {
    }

    public EmployeeBean(String name, LocalDate birthday, int money) {
        this.name = name;
        this.birthday = birthday;
        this.money = money;
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public LocalDate getBirthday() {
        return birthday;
    }

    public void setBirthday(LocalDate birthday) {
        this.birthday = birthday;
    }

    public int getMoney() {
        return money;
    }

    public void setMoney(int money) {
        this.money = money;
    }

    public DeptBean getDept() {
        return dept;
    }

    public void setDept(DeptBean dept) {
        this.dept = dept;
    }

    @Override
    public String toString() {
        return "EmployeeBean{" +
                "id=" + id +
                ", name='" + name + '\'' +
                ", birthday=" + birthday +
                ", money=" + money +
                ", dept=" + dept +
                '}';
    }
}
